﻿//公共js
export function showPrompt(message) {
    return prompt(message, 'Type your name here');
}

//https://developer.aliyun.com/article/1263127
export function windowSize() {
    var size = {
        //屏幕大小
        screenWidth: window.screen.width,
        screenHeight: window.screen.height,
        //可用屏幕大小
        availScreenWidth: window.screen.availWidth,
        availScreenHeight: window.screen.availHeight,
        //窗口外部大小
        windowOuterWidth: window.outerWidth,
        windowOuterHeight: window.outerHeight,
        //窗口内部大小
        windowInnerWidth: window.innerWidth,
        windowInnerHeight: window.innerHeight,
        //不带滚动条的窗口内部大小
        windowInnerWidthNoScroll: document.documentElement.clientWidth,
        windowInnerHeightNoScroll: document.documentElement.clientHeight,
        //网页内容的尺寸
        pageWidth: document.documentElement.scrollWidth,
        pageHeight: document.documentElement.scrollHeight,

    };
    return size;
}